package com.gzhu.knowledgeAdmin.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.gzhu.knowledgeAdmin.common.param.UserInfoParam;
import com.gzhu.knowledgeAdmin.common.vo.MenuVO;
import com.gzhu.knowledgeAdmin.common.vo.PageVo;
import com.gzhu.knowledgeAdmin.entity.Xtyh;

import java.awt.image.BufferedImage;
import java.util.List;
import java.util.Map;

/**
 * 系统用户表
 *
 * @author giaogiao
 * @email giaogiao@gmail.com
 * @date 2023-04-22 23:18:59
 */
public interface XtyhService extends IService<Xtyh> {

    PageVo queryPage(Map<String, Object> params);

    Xtyh selectByUsername(String username);

    Map<String, Object> getUserInfo(String username);

    void saveXtyh(Xtyh xtyh);

    void removeXtyhByIds(List<Integer> ids);

    void updateXtyh(Xtyh xtyh);

    BufferedImage getCaptcha(String uuid);

    boolean validate(String uuid, String code);

    void logout();

    List<MenuVO> getCurUserMenu();

    void resetPwd(List<Integer> ids);

    void updatePwd(UserInfoParam userInfoParam);

    Boolean equlasOldPwd(String oldPassword);

    boolean nameIsExist(String name);

    int hasGrantedRole(String userName);
}

